package com.ruoyi.edu.api.domain;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * 评论对象 edu_comment
 *
 * @author ruoyi
 * @date 2023-09-18
 */
@EqualsAndHashCode(callSuper = true)
@Data
@TableName("edu_comment")
public class EduComment extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * 索引
     */
    @TableId(type = IdType.ASSIGN_ID)
    private String id;

    /**
     * 课程id
     */
    @Excel(name = "课程id")
    private String courseId;

    /**
     * 讲师id
     */
    @Excel(name = "讲师id")
    private String teacherId;

    /**
     * 会员id
     */
    @Excel(name = "会员id")
    private String memberId;

    /**
     * 会员昵称
     */
    @Excel(name = "会员昵称")
    private String nickname;

    /**
     * 会员头像
     */
    @Excel(name = "会员头像")
    private String avatar;

    /**
     * 评论内容
     */
    @Excel(name = "评论内容")
    private String content;

    /**
     * 逻辑删除 1（true）已删除， 0（false）未删除
     */
    @TableLogic
    private String isDeleted;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @TableField(fill = FieldFill.INSERT)
    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date gmtCreate;

    /**
     * 更新时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date gmtModified;

}
